<?php

namespace App\Providers;

use App\Models\Product\ProductFullDetail;
use App\User;
use Illuminate\Support\Facades\Gate;
use Illuminate\Support\ServiceProvider;

class AppServiceProvider extends ServiceProvider
{
    /**
     * Register any application services.
     *
     * @return void
     */
    public function register()
    {
//        $this->app->when('App\Http\Controllers\Product\ProductController')
//            ->needs('App\Models\Product\ProductFullDetail')
//            ->give(function() {
//                return new ProductFullDetail();
//            });
    }

    public function boot()
    {
//        $this->app['auth']->viaRequest('api', function ($request) {
//            if ($request->input('api_token')) {
//                return User::where('api_token', $request->input('api_token'))->first();
//            }
//        });
    }
}
